select top $count [$Primarykey]
from [$Datatable]
order by [$order]